﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;

namespace SindSaude
{
    public partial class OutrosNoticias : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            SindSaudeCamadas.Dados.Noticias noticia = new SindSaudeCamadas.Dados.Noticias(); 
            DataTable dt = new DataTable();
            dt = noticia.carregaOutrosNoticias();
            if (dt.Rows.Count >= 1)
            {
                NoticiasList.DataSource = dt;
                NoticiasList.DataBind();
                NoticiasList.RepeatDirection = RepeatDirection.Horizontal;
            }
        }
        protected void Command_B_Click(object sender, EventArgs e)
        {
            LinkButton btn = sender as LinkButton;
            string url = Convert.ToString(btn.CommandArgument);
            Response.Redirect(url);
        }

    }
}